//
//  HouseCell.swift
//  777Proj
//
//  Created by 陈宇 on 2017/5/9.
//  Copyright © 2017年 🐜. All rights reserved.
//

import UIKit
import Haneke

class HouseCell: UITableViewCell {

    @IBOutlet weak var coverView: UIImageView!
    @IBOutlet weak var primaryLabel: UILabel!
    @IBOutlet weak var minorLabel: UILabel!
    @IBOutlet weak var pirceLabel: UILabel!
    
    var house: House? {
        didSet {
            coverView.hnk_setImageFromURL(APP.APP_PLACEHOLDER_URL, format: Format(name: "cell"))
            primaryLabel.text = house?.name
            minorLabel.text = house?.descriptionField
            pirceLabel.text = "\(house?.price ?? 0)"
        }
    }
    
    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
    }

    override func setSelected(_ selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)

        // Configure the view for the selected state
    }
    
}
